package cn.edu.web.service;

import cn.edu.web.dao.mapper.StaffMapper;
import cn.edu.web.pojo.Staff;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * @Author: shineZhao
 * @Date: 2021/5/9 16:46
 * @Description:
 */

@Transactional
@Service
public class StaffServiceImpl implements StaffService {

    @Autowired
    private StaffMapper staffMapper;

    @Override
    public List<Staff> findAll() {
        System.out.println(staffMapper.findAll());
        return staffMapper.findAll();
    }

    @Override
    public Staff login(Staff staff) {
        return staffMapper.login(staff);
    }
}
